package message

import (
	"github.com/siddontang/go-mysql/mysql"
	"github.com/siddontang/go-mysql/replication"
)

func ProcessMessageBuild(tp string, rowsEvent *replication.RowsEvent,position mysql.Position) *ProcessMessage {

	var message = new(ProcessMessage)

	tableName := string(rowsEvent.Table.Schema) + "." + string(rowsEvent.Table.Table)
	message.TableName = tableName
	message.Operation = tp
	message.Event = rowsEvent
	message.Position = position
	message.Rows = rowsEvent.Rows


	return message
}

func loadMessageBuild(loaderType int,processMessage ProcessMessage) LoadMessage {
	var message LoadMessage
	return message
}